import com.sun.xml.internal.ws.api.model.wsdl.WSDLOutput;

/**
 * Created with IntelliJ IDEA.
 * Description:
 * User: 28779
 * Date: 2023-03-22
 * Time: 18:10
 */
/*class A{
    public int a;

    public A(int a) {
        this.a = a;
    }

    public void setA(int a) {
        this.a = a;
    }

    public int getA(){
        return this.a;
    }
}

class B extends A{

    public B(int a) {
        super(a);
    }
    public int C(){
        return getA();
    }

}*/
class C {
    public C() {

    }

}
class Derived extends C {
/*    public Derived() {
        //super(); // 注意子类构造方法中默认会调用基类的无参构造方法：super(),
        // 用户没有写时,编译器会自动添加，而且super()必须是子类构造方法中第一条语句，
        // 并且只能出现一次
        System.out.println("Derived()");
    }*/

    public Derived() {
        super();
    }
}


public class Person {
/*    public String toString() {
        System.out.print("aaa");
        return "bbb";
    }*/
      Derived B = new Derived();

/*    public static void main(String[] args) {
        A test = new A(10);
        B test1 = new B(20);
        System.out.println(test1.C());*/
}

/*        static int cnt = 6;
        static{
            cnt += 9;
        }
        public static void main(String[] args){
            System.out.println("cnt = " + cnt);
        }
        static{
            cnt /=3;
        };*/
/*    private String name = "Person";

    int age=0;

}

public class Child extends Person{

    public String grade;

    public static void main(String[] args){

        Person p = new Child();

        System.out.println(p.name);

    }*/

//}
